package com.sj.purchase.modules.cost.domain.stock;

import com.sj.purchase.util.excel.annotation.ExcelAttribute;

import javax.persistence.*;
import java.util.Date;

/**
 * Created by 宋开宗 on 2017/7/21 0021.
 */
@Entity
public class StockCost {
	@Id
	@Temporal(TemporalType.DATE)
	@ExcelAttribute(name = "日期", column = "A")
	private Date createDate;
	@ExcelAttribute(name = "数量", column = "B")
	@Column(nullable = false)
	private Long num;
	@ExcelAttribute(name = "成本（平均价）", column = "C")
	@Column(nullable = false)
	private double avgCost;
	@ExcelAttribute(name = "成本（唯一码）", column = "D")
	@Column(nullable = false)
	private double imeiCost;

	public Date getCreateDate() {
		return createDate;
	}

	public StockCost setCreateDate(Date createDate) {
		this.createDate = createDate;
		return this;
	}

	public Long getNum() {
		return num;
	}

	public StockCost setNum(Long num) {
		this.num = num;
		return this;
	}

	public double getAvgCost() {
		return avgCost;
	}

	public StockCost setAvgCost(double avgCost) {
		this.avgCost = avgCost;
		return this;
	}

	public double getImeiCost() {
		return imeiCost;
	}

	public StockCost setImeiCost(double imeiCost) {
		this.imeiCost = imeiCost;
		return this;
	}
}
